#!/usr/local/bin/perl

use strict;

use Getopt::Std;
use Time::Local;

my %opts;
getopts('d', \%opts);

use NBU;
NBU->debug($opts{'d'});
NBU::Media->populate(1);

while (<STDIN>) {
  chop;
  if (my $m = NBU::Media->byID($_)) {
    $m->eject;
  }
}
